Expand all runAtLocation methods to support chunk coordinate arguments#20
Expand all runAtLocation methods to support chunk coordinate arguments#20xGinko wants to merge 1 commit into
Conversation
|
Hey xGinko, typically this developer likes to merge PRs into |
CJCrafter
left a comment
There was a problem hiding this comment.
These changes will be needed to match up with the dev branch.
| * @param consumer Task to run | ||
| * @param delay Delay before execution in ticks | ||
| */ | ||
| void runAtLocationLater(World world, int chunkX, int chunkZ, @NotNull Consumer<WrappedTask> consumer, long delay); |
There was a problem hiding this comment.
This should return a CompleteableFuture<Void>, matching the other methods from #16
| * @param delay Delay before execution | ||
| * @param unit Time unit | ||
| */ | ||
| void runAtLocationLater(World world, int chunkX, int chunkZ, @NotNull Consumer<WrappedTask> consumer, long delay, TimeUnit unit); |
There was a problem hiding this comment.
This should return a CompleteableFuture<Void>, matching the other methods from #16
|
yo @CJCrafter thanks for pointing me in the right direction |
| * @param consumer Task to run | ||
| * @return Future when the task is completed | ||
| */ | ||
| CompletableFuture<Void> runAtLocation(World world, int chunkX, int chunkZ, @NotNull Consumer<WrappedTask> consumer); |
There was a problem hiding this comment.
Could we possibly do runAtChunk please? It makes it a little more obvious what int & int parameters will be. (Same for all other runAtChunk changes)
| * @param consumer Task to run | ||
| * @param delay Delay before execution in ticks | ||
| */ | ||
| void runAtLocationLater(World world, int chunkX, int chunkZ, @NotNull Consumer<WrappedTask> consumer, long delay); |
|
Hey @xGinko , thank you for contributing! As you noticed, we requested a few changes, so there 2 main things that need changing before accepting this:
|
|
@xGinko Should we keep this open? |
|
@TechnicallyCoded I'll make a new one |
|
I was just about to implement methods like these. @xGinko are you still planning to submit a PR for this, or should I create my own? |
Closes #11
Adds support for passing in world and chunk coordinates for all runAtLocation methods.